//SPDX-FileCopyrightText: Copyright 2025-2025 深圳市同心圆网络有限公司
//SPDX-License-Identifier: GPL-3.0-only

package board_dao

import "go.mongodb.org/mongo-driver/mongo"

var BoardInfoDao *_BoardInfoDao
var RemoveBoardInfoDao *_RemoveBoardInfoDao
var MemberInfoDao *_MemberInfoDao
var DrawInfoDao *_DrawInfoDao
var NodeInfoDao *_NodeInfoDao
var EdgeInfoDao *_EdgeInfoDao
var BoardLlmDao *_BoardLlmDao
var ExtDataInfoDao *_ExtDataInfoDao
var MsgInfoDao *_MsgInfoDao
var MsgReadStateDao *_MsgReadStateDao
var InviteDao *_InviteDao

func InitDao(mgoDb *mongo.Database) (err error) {
	BoardInfoDao, err = newBoardInfoDao(mgoDb)
	if err != nil {
		return
	}
	RemoveBoardInfoDao, err = newRemoveBoardInfoDao(mgoDb)
	if err != nil {
		return
	}
	MemberInfoDao, err = newMemberInfoDao(mgoDb)
	if err != nil {
		return
	}
	DrawInfoDao, err = newDrawInfoDao(mgoDb)
	if err != nil {
		return
	}
	NodeInfoDao, err = newNodeInfoDao(mgoDb)
	if err != nil {
		return
	}
	EdgeInfoDao, err = newEdgeInfoDao(mgoDb)
	if err != nil {
		return
	}
	BoardLlmDao, err = newBoardLlmDao(mgoDb)
	if err != nil {
		return
	}
	ExtDataInfoDao, err = newExtDataInfoDao(mgoDb)
	if err != nil {
		return
	}
	MsgInfoDao, err = newMsgInfoDao(mgoDb)
	if err != nil {
		return
	}
	MsgReadStateDao, err = newMsgReadStateDao(mgoDb)
	if err != nil {
		return
	}
	InviteDao, err = newInviteDao(mgoDb)
	if err != nil {
		return
	}
	return
}
